﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Index.Master" AutoEventWireup="true" CodeBehind="home_Cart.aspx.cs" Inherits="Dryricenet.WebForm1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <link href="CSS/home/cart.css" rel="stylesheet" />
    <link href="CSS/home/index.css" rel="stylesheet" />
    <style>
        body {
           /* background: #ffffff;*/
        }
        .delete:hover {
            color:#ffd643;
            text-decoration:underline;
        }
    </style>
    <script src="JS/jquery-3.6.0.js"></script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="quanbu">
        <table id="cartTable">
            <thead>
                <tr>
                    <th>商品</th>
                    <th>单价</th>
                    <th>数量</th>
                    <th>小计</th>
                    <th>操作</th>
                </tr>
            </thead>
            <tbody>
                <asp:Repeater ID="Repeater1" runat="server" OnItemCommand="Repeater1_ItemCommand">
                    <ItemTemplate>
                        <tr>
                            <td class="goods">
                                <asp:Image ID="Image1" runat="server" ImageUrl='<%# Eval("PicUrl") %>' CssClass="goods_img" />
                                <span><%#Eval("FoodName") %></td>
                            <td class="price">
                                <%#Eval("Price") %></td>
                            <td class="count">
                                <%#Eval("Number") %>
                            </td>
                            <td class="subtotal">
                                <%#Eval("Total") %>
                            </td>
                            <td style="display: none;"><%#Eval("FoodID") %></td>
                            <td class="operation">
                                <asp:Button ID="Delete" runat="server" Text="删除" CssClass="delete" Style="border: none; background: none;" OnClick="Delete_Click" CommandArgument='<%#Eval("CartID") %>' CommandName="Delete" OnClientClick="return confirm('是否删除？')" />
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
                <asp:Literal ID="Literal2" runat="server"></asp:Literal>
            </tbody>

        </table>
        <div class="foot" id="foot">
            <div class="fr closing">
                <%--closing--%>
                <%--<a href="home_Order.aspx?foodid=">结 算</a>  --%>
                <asp:Button ID="txtOrder" runat="server" Text="结 算" CssClass="settlement" OnClick="txtOrder_Click" />
            </div>
            <div class="fr total">
                合计：￥
                <span id="priceTotal">
                    <asp:Literal ID="Literal1" runat="server" Text="0.00"></asp:Literal></span>
            </div>
            <div class="fr selected" id="selected">
                已选商品
                <span id="selectedTotal"><%=jian %></span>件
       
                <span class="arrow up">︽</span>
                <span class="arrow down">︾</span>
            </div>
            <div class="selected-view">
                <div id="selectedViewList" class="clearfix">
                    <!--<div><img src="images/1.jpg"><span>取消选择</span></div>-->
                </div>
                <span class="arrow">◆<span>◆</span></span>
            </div>

        </div>

    </div>


</asp:Content>
